package org.sqlproc.engine.impl.type;

import java.sql.ResultSet;
import java.sql.SQLException;

public class SqlIntegerType extends org.hibernate.type.IntegerType {

    @Override
    public Object get(ResultSet rs, String name) throws SQLException {
        if (Character.isDigit(name.charAt(0))) {
            return new Integer(rs.getInt(Integer.parseInt(name)));
        } else {
            return new Integer(rs.getInt(name));
        }
    }
}
